# -*- mode: snippet -*-
# name: shiny server showNotification+autoremove
# key: shiny.server.showNotification.autoremove
# key: shiny_server_showNotification_autoremove
# key: showNotification_autoremove_shiny_server
# contributor: Shuguang Sun
# --
${1:id} <- showNotification("${2:notifications}", type = \"${3:$$(yas-choose-value '("default" "message" "warning" "error"))}\",
duration = NULL, closeButton = FALSE)
on.exit(removeNotification($1), add = TRUE)